/**
 * 
 */
package bot;

/**
 * @author Philip
 *
 */
public class SettingsLoader extends FileLoader {
	public SettingsLoader(String fileName) {
		super(fileName);
	}

	@Override
	public void load(IRCBot ircBot) {
		String server = scan.nextLine();
		int port = Integer.parseInt(scan.nextLine());
		
		ircBot.createConnection(server, port);

		ircBot.setNickName(scan.nextLine());
		ircBot.setFullName(scan.nextLine());
		ircBot.setAuthName(null);

		while (scan.hasNext()) {
			ircBot.addChannel(scan.next());
		}

		scan.close();
	}
}
